<?php
global $Config;
require_once($Config->WebCMSRoot.'Base/Control.php');

Class Code extends BaseControl
{
	var $view;
	
	function Code($parameters, &$page)
	{
		parent::BaseControl($parameters, &$page);
	}

	function Execute()
	{
		global $Config;
		$this->view->output = file_get_contents($Config->SiteRoot.'pages/code/'.$this->GetParameter('code'));
		parent::Execute();
	}

	function ValidateArguments()
	{
		$valid = (count($this->parameters) >= 1);

		return $valid;
	}
}
?>